<!DOCTYPE html>
<html id="docs" lang="en" class="">
	<head>
	<meta charset="utf-8">
<title>Building Large Clusters - Kubernetes</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="shortcut icon" type="image/png" href="../../../images/favicon.png">
<link rel="stylesheet" type="text/css" href="../../../css/base_fonts.css">
<link rel="stylesheet" type="text/css" href="../../../css/styles.css">
<link rel="stylesheet" type="text/css" href="https://code.jquery.com/ui/1.12.1/themes/smoothness/jquery-ui.css">
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.css">
<link rel="stylesheet" type="text/css" href="../../../css/callouts.css">
<link rel="stylesheet" type="text/css" href="../../../css/custom-jekyll/tags.css">




<meta name="description" content="Building Large Clusters" />
<meta property="og:description" content="Building Large Clusters" />

<meta property="og:url" content="https://kubernetes.io/docs/setup/cluster-large/" />
<meta property="og:title" content="Building Large Clusters - Kubernetes" />

<script
src="https://code.jquery.com/jquery-3.2.1.min.js"
integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4="
crossorigin="anonymous"></script>
<script
src="https://code.jquery.com/ui/1.12.1/jquery-ui.min.js"
integrity="sha256-VazP97ZCwtekAsvgPBSUwPFKdrwD3unUfSGVYrahUqU="
crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.js"></script>
<script src="../../../js/script.js"></script>
<script src="../../../js/custom-jekyll/tags.js"></script>


	</head>
	<body>
		<div id="cellophane" onclick="kub.toggleMenu()"></div>

<header>
    <a href="../../../index.html" class="logo"></a>

    <div class="nav-buttons" data-auto-burger="primary">
        <ul class="global-nav">
            
            
            <li><a href="../../home.1">Documentation</a></li>
            
            <li><a href="../../../blog/index.html">Blog</a></li>
            
            <li><a href="../../../partners/index.html">Partners</a></li>
            
            <li><a href="../../../community/index.html">Community</a></li>
            
            <li><a href="../../../case-studies/index.html">Case Studies</a></li>
            
            
             <li>
                <a href="index.html#">
                    English <span class="ui-icon ui-icon-carat-1-s"></span>
                </a>
                <ul>
                
                    <li><a href="../../../zh/index.html">中文 Chinese</a></li>
                
                    <li><a href="../../../ko/index.html">한국어 Korean</a></li>
                
                </ul>
            </li>
         
            <li>
                <a href="index.html#">
                    v1.11 <span class="ui-icon ui-icon-carat-1-s"></span>
                </a>
                <ul>
                
                    <li><a href="https://kubernetes.io">v1.12</a></li>
                
                    <li><a href="../../../index.html">v1.11</a></li>
                
                    <li><a href="https://v1-10.docs.kubernetes.io">v1.10</a></li>
                
                    <li><a href="https://v1-9.docs.kubernetes.io">v1.9</a></li>
                
                </ul>
            </li>
        </ul>
        
        <a href="../../tutorials/kubernetes-basics/index.html" class="button" id="tryKubernetes" data-auto-burger-exclude>Try Kubernetes</a>
        <button id="hamburger" onclick="kub.toggleMenu()" data-auto-burger-exclude><div></div></button>
    </div>

    <nav id="mainNav">
        <main data-auto-burger="primary">
        <div class="nav-box">
            <h3><a href="../../tutorials/stateless-application/hello-minikube/index.html">Get Started</a></h3>
            <p>Ready to get your hands dirty? Build a simple Kubernetes cluster that runs "Hello World" for Node.js.</p>
        </div>
        <div class="nav-box">
            <h3><a href="../../home.1">Documentation</a></h3>
            <p>Learn how to use Kubernetes with the use of walkthroughs, samples, and reference documentation. You can even <a href="../../../editdocs/index.html" data-auto-burger-exclude>help contribute to the docs</a>!</p>
        </div>
        <div class="nav-box">
            <h3><a href="../../../community/index.html">Community</a></h3>
            <p>If you need help, you can connect with other Kubernetes users and the Kubernetes authors, attend community events, and watch video presentations from around the web.</p>
        </div>
        <div class="nav-box">
            <h3><a href="../../../blog/index.html">Blog</a></h3>
            <p>Read the latest news for Kubernetes and the containers space in general, and get technical how-tos hot off the presses.</p>
        </div>
        </main>
        <main data-auto-burger="primary">
        <div class="left">
            <h5 class="github-invite">Interested in hacking on the core Kubernetes code base?</h5>
            <a href="https://github.com/kubernetes/kubernetes" class="button" data-auto-burger-exclude>View On Github</a>
        </div>

        <div class="right">
            <h5 class="github-invite">Explore the community</h5>
            <div class="social">
                <a href="https://twitter.com/kubernetesio" class="twitter"><span>Twitter</span></a>
                <a href="https://github.com/kubernetes/kubernetes" class="github"><span>Github</span></a>
                <a href="http://slack.k8s.io/" class="slack"><span>Slack</span></a>
                <a href="http://stackoverflow.com/questions/tagged/kubernetes" class="stack-overflow"><span>Stack Overflow</span></a>
                <a href="https://discuss.kubernetes.io" class="mailing-list"><span>Forum</span></a>
                <a href="https://calendar.google.com/calendar/embed?src=nt2tcnbtbied3l6gi2h29slvc0%40group.calendar.google.com" class="calendar"><span>Events Calendar</span></a>
            </div>
        </div>
        <div class="clear" style="clear: both"></div>
        </main>
    </nav>
</header>

		
		
		<section id="hero" class="light-text no-sub">
			







<h1>Setup</h1>
<h5></h5>










<div id="vendorStrip" class="light-text">
	<ul>
		
		
		<li><a href="../../home.1">DOCUMENTATION</a></li>
		
		
		<li><a href="../index.html" class="YAH">SETUP</a></li>
		
		
		<li><a href="../../concepts/index.html">CONCEPTS</a></li>
		
		
		<li><a href="../../tasks/index.html">TASKS</a></li>
		
		
		<li><a href="../../tutorials/index.html">TUTORIALS</a></li>
		
		
		<li><a href="../../reference.1">REFERENCE</a></li>
		
	</ul>
	<div id="searchBox">
		<input type="text" id="search" placeholder="Search" onkeydown="if (event.keyCode==13) window.location.replace('/docs/search/?q=' + this.value)" autofocus="autofocus">
	</div>
</div>

		</section>
		
		
<section id="deprecationWarning">
  <main>
    <div class="content deprecation-warning">
      <h3>
        Documentation for Kubernetes v1.11 is no longer actively maintained. The version you are currently viewing is a static snapshot.
        For up-to-date documentation, see the <a href="https://kubernetes.io/docs/home/">latest</a> version.
      </h3>
    </div>
  </main>
</section>


		<section id="encyclopedia">
			
<div id="docsToc">
     <div class="pi-accordion">
    	
        
        
        
        
        
         
             
                 
             
         
             
                 
                          
                          
                 
             
         
             
         
             
         
             
         
             
         
             
         
             
         
         
        
        <a class="item" data-title="Setup" href="../index.html"></a>

	
	
		
		
	<div class="item" data-title="Bootstrapping Clusters with kubeadm">
		<div class="container">
		
		
	
	
		
		
<a class="item" data-title="Customizing control plane configuration with kubeadm" href="../independent/control-plane-flags/index.html"></a>

		
	
		
		
<a class="item" data-title="Creating Highly Available Clusters with kubeadm" href="../independent/high-availability.1"></a>

		
	
		
		
<a class="item" data-title="Creating a single master cluster with kubeadm" href="../../getting-started-guides/kubeadm/index.html"></a>

		
	
		
		
<a class="item" data-title="Troubleshooting kubeadm" href="../independent/troubleshooting-kubeadm/index.html"></a>

		
	

		</div>
	</div>

		
	
		
		
	<div class="item" data-title="Turnkey Cloud Solutions">
		<div class="container">
		
		
	
	
		
		
<a class="item" data-title="Running Kubernetes on AWS EC2" href="../turnkey/aws/index.html"></a>

		
	
		
		
<a class="item" data-title="Running Kubernetes on Alibaba Cloud" href="../turnkey/alibaba-cloud/index.html"></a>

		
	
		
		
<a class="item" data-title="Running Kubernetes on Azure" href="../turnkey/azure/index.html"></a>

		
	
		
		
<a class="item" data-title="Running Kubernetes on CenturyLink Cloud" href="../turnkey/clc/index.html"></a>

		
	
		
		
<a class="item" data-title="Running Kubernetes on Google Compute Engine" href="../turnkey/gce/index.html"></a>

		
	
		
		
<a class="item" data-title="Running Kubernetes on Multiple Clouds with Stackpoint.io" href="../turnkey/stackpoint/index.html"></a>

		
	

		</div>
	</div>

		
	
		
		
	<div class="item" data-title="On-Premises VMs">
		<div class="container">
		
		
	
	
		
		
<a class="item" data-title="Cloudstack" href="../../getting-started-guides/cloudstack/index.html"></a>

		
	
		
		
<a class="item" data-title="Kubernetes on DCOS" href="../../getting-started-guides/dcos/index.html"></a>

		
	
		
		
<a class="item" data-title="oVirt" href="../../getting-started-guides/ovirt.1"></a>

		
	

		</div>
	</div>

		
	
		
		
	<div class="item" data-title="Custom Cloud Solutions">
		<div class="container">
		
		
	
	
		
		
<a class="item" data-title="CoreOS on AWS or GCE" href="../../getting-started-guides/coreos.1"></a>

		
	
		
		
<a class="item" data-title="Installing Kubernetes On-premises/Cloud Providers with Kubespray" href="../../getting-started-guides/kubespray/index.html"></a>

		
	
		
		
<a class="item" data-title="Installing Kubernetes on AWS with kops" href="../custom-cloud/kops.1"></a>

		
	

		</div>
	</div>

		
	
		
		
<a class="item" data-title="Building Large Clusters" href="index.html"></a>

		
	
		
		
<a class="item" data-title="Building from Source" href="../building-from-source/index.html"></a>

		
	
		
		
<a class="item" data-title="Configuring Kubernetes with Salt" href="../salt/index.html"></a>

		
	
		
		
<a class="item" data-title="Creating a Custom Cluster from Scratch" href="../../getting-started-guides/scratch/index.html"></a>

		
	
		
		
<a class="item" data-title="Picking the Right Solution" href="../../getting-started-guides/index.html"></a>

		
	
		
		
<a class="item" data-title="Running Kubernetes Locally via Minikube" href="../../getting-started-guides/minikube/index.html"></a>

		
	
		
		
<a class="item" data-title="Running in Multiple Zones" href="../multiple-zones.1"></a>

		
	
		
		
<a class="item" data-title="Validate Node Setup" href="../node-conformance/index.html"></a>

		
	






     </div> 
    <button class="push-menu-close-button" onclick="kub.toggleToc()"></button>
</div> 

			<div id="docsContent">
				
<p><a href="../../editdocs#docs/setup/cluster-large.md" id="editPageButton">Edit This Page</a></p>

<h1>Building Large Clusters</h1>





<h2 id="support">Support</h2>

<p>At v1.11, Kubernetes supports clusters with up to 5000 nodes. More specifically, we support configurations that meet <em>all</em> of the following criteria:</p>

<ul>
<li>No more than 5000 nodes</li>
<li>No more than 150000 total pods</li>
<li>No more than 300000 total containers</li>
<li>No more than 100 pods per node</li>
</ul>

<p><br></p>

<nav id="TableOfContents">
<ul>
<li>
<ul>
<li><a href="index.html#support">Support</a></li>
<li><a href="index.html#setup">Setup</a>
<ul>
<li><a href="index.html#quota-issues">Quota Issues</a></li>
<li><a href="index.html#etcd-storage">Etcd storage</a></li>
<li><a href="index.html#size-of-master-and-master-components">Size of master and master components</a></li>
<li><a href="index.html#addon-resources">Addon Resources</a></li>
<li><a href="index.html#allowing-minor-node-failure-at-startup">Allowing minor node failure at startup</a></li>
</ul></li>
</ul></li>
</ul>
</nav>

<h2 id="setup">Setup</h2>

<p>A cluster is a set of nodes (physical or virtual machines) running Kubernetes agents, managed by a &ldquo;master&rdquo; (the cluster-level control plane).</p>

<p>Normally the number of nodes in a cluster is controlled by the value <code>NUM_NODES</code> in the platform-specific <code>config-default.sh</code> file (for example, see <a href="http://releases.k8s.io/v1.11.3/cluster/gce/config-default.sh" target="_blank">GCE&rsquo;s <code>config-default.sh</code></a>).</p>

<p>Simply changing that value to something very large, however, may cause the setup script to fail for many cloud providers. A GCE deployment, for example, will run in to quota issues and fail to bring the cluster up.</p>

<p>When setting up a large Kubernetes cluster, the following issues must be considered.</p>

<h3 id="quota-issues">Quota Issues</h3>

<p>To avoid running into cloud provider quota issues, when creating a cluster with many nodes, consider:</p>

<ul>
<li>Increase the quota for things like CPU, IPs, etc.

<ul>
<li>In <a href="https://cloud.google.com/compute/docs/resource-quotas" target="_blank">GCE, for example,</a> you&rsquo;ll want to increase the quota for:</li>
<li>CPUs</li>
<li>VM instances</li>
<li>Total persistent disk reserved</li>
<li>In-use IP addresses</li>
<li>Firewall Rules</li>
<li>Forwarding rules</li>
<li>Routes</li>
<li>Target pools</li>
</ul></li>
<li>Gating the setup script so that it brings up new node VMs in smaller batches with waits in between, because some cloud providers rate limit the creation of VMs.</li>
</ul>

<h3 id="etcd-storage">Etcd storage</h3>

<p>To improve performance of large clusters, we store events in a separate dedicated etcd instance.</p>

<p>When creating a cluster, existing salt scripts:</p>

<ul>
<li>start and configure additional etcd instance</li>
<li>configure api-server to use it for storing events</li>
</ul>

<h3 id="size-of-master-and-master-components">Size of master and master components</h3>

<p>On GCE/Google Kubernetes Engine, and AWS, <code>kube-up</code> automatically configures the proper VM size for your master depending on the number of nodes
in your cluster. On other providers, you will need to configure it manually. For reference, the sizes we use on GCE are</p>

<ul>
<li>1-5 nodes: n1-standard-1</li>
<li>6-10 nodes: n1-standard-2</li>
<li>11-100 nodes: n1-standard-4</li>
<li>101-250 nodes: n1-standard-8</li>
<li>251-500 nodes: n1-standard-16</li>
<li>more than 500 nodes: n1-standard-32</li>
</ul>

<p>And the sizes we use on AWS are</p>

<ul>
<li>1-5 nodes: m3.medium</li>
<li>6-10 nodes: m3.large</li>
<li>11-100 nodes: m3.xlarge</li>
<li>101-250 nodes: m3.2xlarge</li>
<li>251-500 nodes: c4.4xlarge</li>
<li>more than 500 nodes: c4.8xlarge</li>
</ul>

<p>Note that these master node sizes are currently only set at cluster startup time, and are not adjusted if you later scale your cluster up or down (e.g. manually removing or adding nodes, or using a cluster autoscaler).</p>

<h3 id="addon-resources">Addon Resources</h3>

<p>To prevent memory leaks or other resource issues in <a href="https://releases.k8s.io/v1.11.3/cluster/addons" target="_blank">cluster addons</a> from consuming all the resources available on a node, Kubernetes sets resource limits on addon containers to limit the CPU and Memory resources they can consume (See PR <a href="http://pr.k8s.io/10653/files" target="_blank">#10653</a> and <a href="http://pr.k8s.io/10778/files" target="_blank">#10778</a>).</p>

<p>For example:</p>
<div class="highlight"><pre style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4"><code class="language-yaml" data-lang="yaml"><span style="color:#bbb">  </span>containers:<span style="color:#bbb">
</span><span style="color:#bbb">  </span>-<span style="color:#bbb"> </span>name:<span style="color:#bbb"> </span>fluentd-cloud-logging<span style="color:#bbb">
</span><span style="color:#bbb">    </span>image:<span style="color:#bbb"> </span>k8s.gcr.io/fluentd-gcp:<span style="color:#666">1.16</span><span style="color:#bbb">
</span><span style="color:#bbb">    </span>resources:<span style="color:#bbb">
</span><span style="color:#bbb">      </span>limits:<span style="color:#bbb">
</span><span style="color:#bbb">        </span>cpu:<span style="color:#bbb"> </span>100m<span style="color:#bbb">
</span><span style="color:#bbb">        </span>memory:<span style="color:#bbb"> </span>200Mi</code></pre></div>
<p>Except for Heapster, these limits are static and are based on data we collected from addons running on 4-node clusters (see <a href="http://issue.k8s.io/10335#issuecomment-117861225" target="_blank">#10335</a>). The addons consume a lot more resources when running on large deployment clusters (see <a href="http://issue.k8s.io/5880#issuecomment-113984085" target="_blank">#5880</a>). So, if a large cluster is deployed without adjusting these values, the addons may continuously get killed because they keep hitting the limits.</p>

<p>To avoid running into cluster addon resource issues, when creating a cluster with many nodes, consider the following:</p>

<ul>
<li>Scale memory and CPU limits for each of the following addons, if used, as you scale up the size of cluster (there is one replica of each handling the entire cluster so memory and CPU usage tends to grow proportionally with size/load on cluster):

<ul>
<li><a href="http://releases.k8s.io/v1.11.3/cluster/addons/cluster-monitoring/influxdb/influxdb-grafana-controller.yaml" target="_blank">InfluxDB and Grafana</a></li>
<li><a href="http://releases.k8s.io/v1.11.3/cluster/addons/dns/kube-dns.yaml.in" target="_blank">kubedns, dnsmasq, and sidecar</a></li>
<li><a href="http://releases.k8s.io/v1.11.3/cluster/addons/fluentd-elasticsearch/kibana-deployment.yaml" target="_blank">Kibana</a></li>
</ul></li>
<li>Scale number of replicas for the following addons, if used, along with the size of cluster (there are multiple replicas of each so increasing replicas should help handle increased load, but, since load per replica also increases slightly, also consider increasing CPU/memory limits):

<ul>
<li><a href="http://releases.k8s.io/v1.11.3/cluster/addons/fluentd-elasticsearch/es-statefulset.yaml" target="_blank">elasticsearch</a></li>
</ul></li>
<li>Increase memory and CPU limits slightly for each of the following addons, if used, along with the size of cluster (there is one replica per node but CPU/memory usage increases slightly along with cluster load/size as well):

<ul>
<li><a href="http://releases.k8s.io/v1.11.3/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml" target="_blank">FluentD with ElasticSearch Plugin</a></li>
<li><a href="http://releases.k8s.io/v1.11.3/cluster/addons/fluentd-gcp/fluentd-gcp-ds.yaml" target="_blank">FluentD with GCP Plugin</a></li>
</ul></li>
</ul>

<p>Heapster&rsquo;s resource limits are set dynamically based on the initial size of your cluster (see <a href="http://issue.k8s.io/16185" target="_blank">#16185</a>
and <a href="http://issue.k8s.io/22940" target="_blank">#22940</a>). If you find that Heapster is running
out of resources, you should adjust the formulas that compute heapster memory request (see those PRs for details).</p>

<p>For directions on how to detect if addon containers are hitting resource limits, see the <a href="../../user-guide/compute-resources/index.html#troubleshooting">Troubleshooting section of Compute Resources</a>.</p>

<p>In the <a href="http://issue.k8s.io/13048" target="_blank">future</a>, we anticipate to set all cluster addon resource limits based on cluster size, and to dynamically adjust them if you grow or shrink your cluster.
We welcome PRs that implement those features.</p>

<h3 id="allowing-minor-node-failure-at-startup">Allowing minor node failure at startup</h3>

<p>For various reasons (see <a href="https://github.com/kubernetes/kubernetes/issues/18969" target="_blank">#18969</a> for more details) running
<code>kube-up.sh</code> with a very large <code>NUM_NODES</code> may fail due to a very small number of nodes not coming up properly.
Currently you have two choices: restart the cluster (<code>kube-down.sh</code> and then <code>kube-up.sh</code> again), or before
running <code>kube-up.sh</code> set the environment variable <code>ALLOWED_NOTREADY_NODES</code> to whatever value you feel comfortable
with. This will allow <code>kube-up.sh</code> to succeed with fewer than <code>NUM_NODES</code> coming up. Depending on the
reason for the failure, those additional nodes may join later or the cluster may remain at a size of
<code>NUM_NODES - ALLOWED_NOTREADY_NODES</code>.</p>



				<div class="issue-button-container">
					<p><a href="index.html"><img src="https://kubernetes-site.appspot.com/UA-36037335-10/GitHub/docs/setup/cluster-large.md?pixel" alt="Analytics" /></a></p>
					
					
					<script type="text/javascript">
					PDRTJS_settings_8345992 = {
					"id" : "8345992",
					"unique_id" : "\/docs\/setup\/cluster-large\/",
					"title" : "Building Large Clusters",
					"permalink" : "https:\/\/kubernetes.io\/docs\/setup\/cluster-large\/"
					};
					(function(d,c,j){if(!document.getElementById(j)){var pd=d.createElement(c),s;pd.id=j;pd.src=('https:'==document.location.protocol)?'https://polldaddy.com/js/rating/rating.js':'http://i0.poll.fm/js/rating/rating.js';s=document.getElementsByTagName(c)[0];s.parentNode.insertBefore(pd,s);}}(document,'script','pd-rating-js'));
					</script>
					<a href="index.html" onclick="window.open('https://github.com/kubernetes/website/issues/new?title=Issue%20with%20' +
					'k8s.io'+window.location.pathname)" class="button issue">Create an Issue</a>
					
					
					
					<a href="../../editdocs#docs/setup/cluster-large.md" class="button issue">Edit this Page</a>
					
				</div>
			</div>
		</section>
		<footer>
    <main class="light-text">
        <nav>
            
            
            
            <a href="../../home.1">Documentation</a>
            
            <a href="../../../blog/index.html">Blog</a>
            
            <a href="../../../partners/index.html">Partners</a>
            
            <a href="../../../community/index.html">Community</a>
            
            <a href="../../../case-studies/index.html">Case Studies</a>
            
        </nav>
        <div class="social">
            <div>
                <a href="https://twitter.com/kubernetesio" class="twitter"><span>twitter</span></a>
                <a href="https://github.com/kubernetes/kubernetes" class="github"><span>Github</span></a>
                <a href="http://slack.k8s.io/" class="slack"><span>Slack</span></a>
            </div>
            <div>
                <a href="http://stackoverflow.com/questions/tagged/kubernetes" class="stack-overflow"><span>Stack Overflow</span></a>
                <a href="https://discuss.kubernetes.io" class="mailing-list"><span>Forum</span></a>
                <a href="https://calendar.google.com/calendar/embed?src=nt2tcnbtbied3l6gi2h29slvc0%40group.calendar.google.com" class="calendar"><span>Events Calendar</span></a>
            </div>
            <div>
                <a href="../../getting-started-guides/index.html" class="button">Get Kubernetes</a>
                <a href="https://git.k8s.io/community/contributors/guide" class="button">Contribute</a>
            </div>
        </div>
        <div id="miceType" class="center">
            &copy; 2018 The Kubernetes Authors | Documentation Distributed under <a href="https://git.k8s.io/website/LICENSE" class="light-text">CC BY 4.0</a>
        </div>
        <div id="miceType" class="center">
            Copyright &copy; 2018 The Linux Foundation&reg;. All rights reserved. The Linux Foundation has registered trademarks and uses trademarks. For a list of trademarks of The Linux Foundation, please see our <a href="https://www.linuxfoundation.org/trademark-usage" class="light-text">Trademark Usage page</a>
        </div>
    </main>
</footer>

		<button class="flyout-button" onclick="kub.toggleToc()"></button>

<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
    (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-36037335-10', 'auto');
ga('send', 'pageview');


(function () {
    window.addEventListener('DOMContentLoaded', init)

        
        function init() {
            window.removeEventListener('DOMContentLoaded', init)
                hideNav()
        }

    function hideNav(toc){
        if (!toc) toc = document.querySelector('#docsToc')
        if (!toc) return
            var container = toc.querySelector('.container')

                
                if (container) {
                    if (container.childElementCount === 0 || toc.querySelectorAll('a.item').length === 1) {
                        toc.style.display = 'none'
                            document.getElementById('docsContent').style.width = '100%'
                    }
                } else {
                    requestAnimationFrame(function () {
                        hideNav(toc)
                    })
                }
    }
})();
</script>



	</body>
</html>